﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="UC_Dathang.ascx.cs" Inherits="Controls_UC_Dathang" %>
<div id="Breadcrumb">
    <ul>
        <li><a href="Trangchu.aspx">Trang chủ</a></li>
        <li>Thông tin đặt hàng</li>
    </ul>
</div>
<div id="dathang">
    <div class="main-items">
        <div class="tieude-items">
            <h4>
                1. Người đăng nhập</h4>
        </div>
        <div class="content-items">
            <div class="info-login">
                <p>
                    Họ tên: <span>
                        <asp:Label ID="lblUserName" runat="server"></asp:Label></span></p>
                <p>
                    Đỉa chỉ email: <span>
                        <asp:Label ID="lblUserMail" runat="server"></asp:Label></span></p>
            </div>
        </div>
    </div>
    <div class="main-items">
        <div class="tieude-items">
            <h3>
                2. Địa chỉ giao hàng</h3>
        </div>
        <div class="content-items">
            <div class="diachi-giaohang">
                <p class="pchu">
                    <span class="price">*</span>Họ tên:</p>
                <p class="pinput">
                    <asp:TextBox ID="txtCus_Name" CssClass="diachi-giaohang-box" runat="server"></asp:TextBox>
                    <%--<input type="text" id="hoten-giaohang" value="" name="hoten_giaohang"></p>--%></p>
                <div class="clear">
                </div>
                <p class="pchu">
                    <span class="price">*</span>Địa chỉ:</p>
                <p class="pinput">
                    <asp:TextBox ID="txtCus_Add" CssClass="diachi-giaohang-box" runat="server"></asp:TextBox>
                    <%--<input type="text" id="diachi-giaohang" value="" name="diachi_giaohang" size="60">--%></p>
                <div class="clear">
                </div>
                <p class="pchu">
                    <span class="price">*</span>Tỉnh thành:</p>
                <p class="pinput">
                    <asp:DropDownList ID="drlProvince" CssClass="diachi-giaohang-box" runat="server">
                    </asp:DropDownList>
                </p>
                <div class="clear">
                </div>
                <p class="pchu">
                    <span class="price">*</span>Điện thoại:</p>
                <p class="pinput">
                    <asp:TextBox ID="txtCus_Phone" CssClass="diachi-giaohang-box" runat="server"></asp:TextBox>
                    <%--<input type="text" onkeypress="return keypress(event);" id="dienthoai-giaohang" value=""
                    name="dienthoai_giaohang">--%></p>
                <div class="clear">
                </div>
            </div>
        </div>
    </div>
    <div class="main-items">
        <div class="tieude-items">
            <h3>
                3. Thanh toán và vận chuyển</h3>
        </div>
        <div class="content-items">
            <div class="phuongthuc">
                <div id="phuongthuc-thanhtoan">
                    <p class="luachon">
                        <strong>Lựa chọn phương thức thanh toán</strong></p>
                    <asp:DropDownList ID="drlPayMethod" CssClass="diachi-giaohang-box" runat="server"
                        Width="310px">
                    </asp:DropDownList>
                </div>
                <div id="phuongthuc-vanchuyen">
                    <p class="luachon">
                        <strong>Phương thức vận chuyển</strong></p>
                    <p>
                        <strong>Nhà cung cấp:</strong> Công ty TNHH Đồng Hồ DL</p>
                    <%--<ul>
                        <li>Laptop Toshiba Satellite L840 32372G50G</li>
                    </ul>--%>
                    <p>
                        <input type="radio" id="tieude-items-quathe" checked="checked" value="1" name="phuongthuc_vc" />
                        Chuyển phát nhanh ( 3-5 ngày) - 60,000 VNĐ</p>
                    <p id="tong">
                        <strong>Tổng: <span class="price">60,000 VNĐ</span></strong></p>
                </div>
                <div class="clear">
                </div>
            </div>
        </div>
    </div>
    <div class="main-items">
        <div class="tieude-items">
            <h3>
                4. Kiểm tra lại thông tin và đặt hàng</h3>
        </div>
        <div class="content-items">
            <div>
                <h4>
                    Sản phẩm trong đơn đặt hàng của bạn</h4>
            </div>
            <div class="kiemtra">
                <asp:GridView ID="gvGiohang" runat="server" AutoGenerateColumns="False" CellPadding="4"
                    GridLines="None" ForeColor="#333333" CssClass="tbGiohang">
                    <AlternatingRowStyle BackColor="White" />
                    <Columns>
                        <asp:TemplateField HeaderText="STT">
                            <ItemTemplate>
                                <%# Container.DataItemIndex + 1 %>
                            </ItemTemplate>
                            <ControlStyle Width="70px" />
                            <ItemStyle HorizontalAlign="Center" VerticalAlign="Middle" />
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Tên Sản Phẩm">
                            <ItemTemplate>
                                <a href='Chi-tiet-san-pham.aspx?Id=<%#Eval("idSp") %>'>
                                    <asp:Label ID="Label1" Text='<%#Eval("TenSP") %>' runat="server" /></a>
                            </ItemTemplate>
                            <ControlStyle Width="250px" />
                            <ItemStyle HorizontalAlign="Center" VerticalAlign="Middle" />
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Đơn giá">
                            <ItemTemplate>
                                <asp:Label ID="Label2" Text='<%#dinhdangtien(Eval("Gia").ToString()) %>' runat="server" />
                            </ItemTemplate>
                            <ControlStyle Width="150px" />
                            <ItemStyle HorizontalAlign="Center" VerticalAlign="Middle" />
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Số lượng">
                            <ItemTemplate>
                                <asp:Label ID="Label3" Text='<%#Eval("SoLuong") %>' runat="server" />
                                <%--<asp:TextBox Text='<%#Eval("SoLuong") %>' runat="server" CssClass="txtSoluong" ID="txtSoLuong" />--%>
                            </ItemTemplate>
                            <ItemStyle HorizontalAlign="Center" VerticalAlign="Middle" />
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Thành tiền">
                            <ItemTemplate>
                                <asp:Label ID="Label4" Text='<%#dinhdangtien(Eval("TongTien").ToString()) %>' runat="server" />
                            </ItemTemplate>
                            <ControlStyle Width="150px" />
                            <ItemStyle HorizontalAlign="Center" VerticalAlign="Middle" />
                        </asp:TemplateField>
                    </Columns>
                    <EditRowStyle BackColor="#2461BF" />
                    <FooterStyle BackColor="#507CD1" ForeColor="White" Font-Bold="True" />
                    <HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" Height="40" Font-Size="14px" />
                    <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
                    <RowStyle BackColor="#EFF3FB" />
                    <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
                    <SortedAscendingCellStyle BackColor="#F5F7FB" />
                    <SortedAscendingHeaderStyle BackColor="#6D95E1" />
                    <SortedDescendingCellStyle BackColor="#E9EBEF" />
                    <SortedDescendingHeaderStyle BackColor="#4870BE" />
                </asp:GridView>
                <div class="thongbao">
                    <asp:Literal ID="ltrThongbao" runat="server"></asp:Literal>
                </div>
                <div id="thongke">
                    <ul>
                        <li class="subtotal"><span><strong>Tổng:</strong></span> <strong>
                            <asp:Literal ID="ltrTongTien" runat="server"></asp:Literal></strong> </li>
                        <li class="subtotal"><span>Phí vận chuyển:</span> <strong>60.000 VNĐ</strong> </li>
                        <li class="total"><strong>Tổng chi phí:</strong> <span class="price" id="tong_chi_phi">
                            <asp:Label ID="lblTongTien" runat="server"></asp:Label></span> <span class="price">VNĐ</span>
                        </li>
                    </ul>
                </div>
                <div class="clear">
                </div>
                <div id="button-dathang">
                    <asp:Button ID="btnDatHang" runat="server" Text="Đặt hàng" OnClick="btnDatHang_Click" />
                </div>
                <div class="clear">
                </div>
            </div>
        </div>
    </div>
</div>
<asp:Literal ID="Literal1" runat="server"></asp:Literal>